package com.kingja.sample;

import com.kingja.loadsir.callback.SuccessCallback;
import com.kingja.loadsir.core.LoadSir;
import com.kingja.sample.callback.*;
import ohos.aafwk.ability.AbilityPackage;

public class App extends AbilityPackage {
    @Override
    public void onInitialize() {
        super.onInitialize();
        LoadSir.beginBuilder()
                .addCallback(new ErrorCallback())
                .addCallback(new EmptyCallback())
                .addCallback(new LoadingCallback())
                .addCallback(new TimeoutCallback())
                .addCallback(new CustomCallback())
                .setDefaultCallback(SuccessCallback.class)
                .commit();
    }
}
